/*
 * @Author: pengtianrui 2276608413@qq.com
 * @Date: 2024-07-19 14:42:56
 * @LastEditors: 武兴创 superjava@vip.qq.com
 * @LastEditTime: 2024-08-28 17:40:56
 * @FilePath: \SGFEM\DataStructure\FEM\Material\include\Orthotropic2DMaterial.h
 * @Description: 二维线弹性温度无关正交各项异性材料
 * 线弹性正交各项异性材料支持的各项属性数据。
 * MAT8
 */
#pragma once
#include "DataStructure/Common/DataStructureNamespace.h"
#include "DataStructure/Common/Id.h"
#include "DataStructure/Common/Real.h"
#include "DataStructure/Input/Material/MaterialBase.h"

#include "MaterialTypes.h"

SG_DATASTRUCTURE_FEM_NAMESPACE_OPEN
struct Orthotropic2DMaterial : public MaterialBase
{
    /// @brief 构造函数，创建各项异性材料
    /// @param id 材料属性号，默认0
    // Orthotropic2DMaterial (SG::DataStructure::Common::Id id = 0);
    SG::DataStructure::Common::Real m_E1             = 0.0;      ///< x/1方向弹性模量
    SG::DataStructure::Common::Real m_E2             = 0.0;      ///< y/2方向弹性模量
    SG::DataStructure::Common::Real m_nu12           = 0.0;      ///< 泊松比
    SG::DataStructure::Common::Real m_G12            = 0.0;      ///< 平面内剪切模量
    SG::DataStructure::Common::Real m_G1Z            = 0.0;      ///< x-Z/1-Z剪切模量
    SG::DataStructure::Common::Real m_G2Z            = 0.0;      ///< y-Z/2-Z剪切模量
    SG::DataStructure::Common::Real m_rho            = 0.0;      ///< 密度
    SG::DataStructure::Common::Real m_A1             = 0.0;      ///< x/1方向热膨胀系数
    SG::DataStructure::Common::Real m_A2             = 0.0;      ///< y/2方向热膨胀系数
    SG::DataStructure::Common::Real m_tref           = 0.0;      ///< 参考温度
    SG::DataStructure::Common::Real m_XT             = 0.0;      ///< x/1方向拉伸强度极限
    SG::DataStructure::Common::Real m_XC             = 0.0;      ///< x/1方向压缩强度极限
    SG::DataStructure::Common::Real m_YT             = 0.0;      ///< y/2方向拉伸强度极限
    SG::DataStructure::Common::Real m_YC             = 0.0;      ///< y/2方向压缩强度极限
    SG::DataStructure::Common::Real m_S              = 0.0;      ///< 剪切强度极限
    SG::DataStructure::Common::Real m_ge             = 0.0;      ///< 单元阻尼
    SG::DataStructure::Common::Real m_F12            = 0.0;      ///< Tsai-Wu 交叉项系数
    SG::DataStructure::Common::Real m_Strn           = 0.0;      /// m_XT - m_Yc 对应的是应力还是应变的强度极限
    SG::DataStructure::Common::Id   m_domainId       = 0;
    SG::DataStructure::Common::Real m_HFAILFactor[6] = { 0.0 };  //< 失效准则参数
    SG::DataStructure::Common::Real m_HTAPEFactor[9] = { 0.0 };
    SG::DataStructure::Common::Real m_HFABRFactor[9] = { 0.0 };

    static MaterialTypes GetType ()
    {
        return MaterialTypes::MATTYPE_2DOrthotropic;
    };
};

DECLSPEC bool operator== (const Orthotropic2DMaterial& a, const Orthotropic2DMaterial& b);

SG_DATASTRUCTURE_FEM_NAMESPACE_CLOSE